﻿using Newtonsoft.Json;

namespace AutomationCommand
{
    public class table_read : BasiCommand
    {
        [JsonProperty("fun_type")]
        public string FunType { get; set; }

        [JsonProperty("othername")]
        public string OtherName { get; set; }

        [JsonProperty("dir")]
        public string Directory { get; set; }

        [JsonProperty("tablename")]
        public string TableName { get; set; }

        [JsonProperty("colums")]
        public string Columns { get; set; }

        [JsonProperty("condition")]
        public string Condition { get; set; }

        public table_read()
        {
            FunType = "table_read";
            OtherName = "读取表格";
            Directory = "";
            TableName = "";
            Columns = "*";
            Condition = "";
            SuccessJump = -1;
            FailureJump = -1;
        }

        public  bool Execute()
        {
            // 在这里编写执行读取表格命令的逻辑
            // 返回执行结果
            return true; // 假设此处始终成功
        }
    }
}
